import instance from '@/utils/request.js'

export const getCommentList = (params) => {
  return instance({
    url: '/comment/list',
    method: 'get',
    params,
  })
}
export const editComment = ( data) => {

  return instance({
    url: '/comment',
    method: 'put',
    data,
  })
}

export const deleteComment = (id) => {
  return instance({
    url: `/comment/${id}`,
    method: 'delete',
  })
}

export const addComment = (data) => {
  return instance({
    url: '/comment',
    method: 'post',
    data,
  })
}
